<?php

/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */

/**
 * Description of test
 *
 * @author Albadr
 */
class Test extends CI_Controller {

    public function search() {
        $results[0]->title = "Judul Dummy Kesatu";
        $results[0]->no = 0;
        $results[1]->no = 1;
        $results[2]->no = 2;
        $results[3]->no = 3;
        $results[1]->title = "Judul Dummy Kedua";
        $results[2]->title = "Judul Dummy Ketiga";
        $results[3]->title = "Judul Dummy Keempat";
        $time = 12.12133121;
        
        $this->load->view('search',array(
            'results'=>$results,
            'time'=>$time
        ));
    }
    public function experiment() {
        
        
        for ($i=1;$i<20;$i++){
            $results[$i]->title = "Judul Dokumen Dummy Ke-".$i;
            $results[$i]->no = $i;
        }
        
        for ($i=1;$i<20;$i++){
            $queries[$i]->no = $i;
            $queries[$i]->query = "Query ".$i;
            $queries[$i]->results = $results;
            $queries[$i]->niap = 0.8;
        }
        
        $this->load->view('experiment',array(
            "qresult"=>$queries,
            "avrniap"=>0.99,
            "time"=>1.122
        ));
    }
    
    private function _v($l){
        $l = 4;
        
        return $l*$l;
    }
}

?>
